function http(url){
  return new Promise((resolve,reject)=>{
    wx.request({
      url,
      dataType: "json",
      header: {"content-type":"application"},
      method: "GET",
      responseType: "text",
      success: res => resolve(res),
      fail:err=>reject(res)
    })
  })
}

module.exports={
  http
}